#ifndef __UNIFORME_ALLOC_DISTRIBUTION__
#define __UNIFORME_ALLOC_DISTRIBUTION__



#include <boost/random/uniform_int.hpp>
#include "generateurs.hpp"

/*
 *Une distribution uniforme des blocs {1,2,4,8,16,32,64,........,2^{ordre}}
 */

#include "IAllocDistribution.hpp"
class UniformeAllocDistribution : public virtual IAllocDistribution
{
  
public:
  UniformeAllocDistribution(int ordre):IAllocDistribution()
  {
    this->ordre = ordre;
  };
  
  virtual void genererBloc(unsigned int id);
  virtual void initGenerateur();
  virtual void finitGenerateur();
 
  
private:
  int ordre;
  boost::uniform_int<> * uniforme;
  generateurs::base_generator_type* generateur;
  
};

#endif
